<?php 
if($this->session->flashdata('profile_errors'))
{	?>
	<div class="alert alert-danger">
		<?= $this->session->flashdata('profile_errors') ?>
	</div>
<?php
}
elseif($this->session->flashdata('profile_success'))
{	?>
		<div class="alert alert-success">
			<?= $this->session->flashdata('profile_success') ?>
		</div>
<?php
	}	?>
<header class="well rounded">
	<h1>Welcome Professor</h1>
</header>
<div class="row">
	<div id="file_manager" class="span3 well rounded">
		<p class="lead">Your files</p>
<?php 
	if(isset($files))
	{	?>
		<ul id="user_files">
	<?php 
		foreach($files as $file)
		{	?>
			<li>
				<i class="icon-large icon-file"></i>
				<a href="<?= $file['file_path'] ?>"><?= $file['file_name'] ?></a>
			</li>
<?php	}	?>
		</ul>
<?php
	}
	else
	{	?>
		<h3 class="well rounded muted">No files yet</h3>
<?php	
	}	?>		
		<p class="lead">Upload</p>
		<?= form_open_multipart('user/upload') ?>
			<input type="file" name="userfile">
			<button type="submit" class="btn btn-primary">Upload</button>
		<?= form_close()  ?>
	</div>
	<div id="news_feed" class="span8 well rounded">
		<p class="lead">Recent updates</p>
		<ul class="media-list">
<?php 	
	if(isset($news))
	{	
		foreach($news as $feed)
		{	?>
			<li class="media">
	      		<img class="pull-left media-object" src="/assets/img/photo_thumbnail.gif">
			    <div class="media-body">
			    	<h4 class="media-heading">Rey Christopher Ali</h4>
			    	<p>Hey hey hey</p>
			    	<small class="muted">2 seconds ago</small>
		    		<!-- <div class="media">
			      		<img class="media-object pull-left" src="/assets/img/photo_thumbnail.gif">
					    <div class="media-body">
					    	<h4 class="media-heading">Mac</h4>
					    	<p>Test reply</p>
					    	<small class="muted">2 seconds ago</small>
					    </div>
					</div> -->
			    </div>
			</li>
<?php	}
	}	?>
		</ul>
	</div>
</div>